package org.atlantis.sbe.actor

import scala.actors.Actor
import java.util.Date

trait AuctionMessage // 客户向拍卖官发送的消息
case class Offer(bid: Int, client: Actor) extends AuctionMessage // 出价消息
case class Inquire(client: Actor) extends AuctionMessage // 询问消息

trait AuctionReply // 拍卖官向客户回复的消息
case class Status(asked: Int, expire: Date) extends AuctionReply // 询问消息（有没有人出更高价？之类的消息）
case object BestOffer extends AuctionReply // 最高的价格消息（告诉客户，你的价格现在是最高的）
case class BeatenOffer(maxBid: Int) extends AuctionReply // 价格被别人超过的消息 
case class AuctionConcluded(seller: Actor, client: Actor) extends AuctionReply // 拍卖结果消息
case object AuctionFailed extends AuctionReply // 拍卖失败消息
case object AuctionOver extends AuctionReply // 拍卖结束消息